package com.acme.task3;

public class Task3Arrays {
	
	private static double avg(int[] array){
		int arrayLength = array.length, i = 0, sum = 0;
		for (i = 0; i < arrayLength; i ++){
			sum += array[i];
		}
		return (sum / arrayLength);
	}
	
	public static void main(String[] args) {
		int[] array = new int[50];
		for (int i = 1; i < array.length; i++) {
			array[i] = i;
			if (i % 3 == 0)
				System.out.println("Number " + i + " is multiple of 3");
			else
				System.out.println(i);
		}
		System.out.println("Average of array = " + avg(array));
		
	}
}
